/*
 * @Author: DT1604\ZPL zhoupeili@dpc.com.cn
 * @Date: 2022-05-25 16:46:47
 * @LastEditors: DT1604\ZPL zhoupeili@dpc.com.cn
 * @LastEditTime: 2022-06-10 17:15:56
 * @FilePath: \energy-om-platform\src\api\login.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import request from '@/utils/request'

export function login(url, params) {
  return request({
    url: '/api/user' + url,
    method: 'get',
    params
  })
}
export function users(url, method, type, data) {
  let object = {
    url: '/api/user' + url,
    method: method || 'post',
  }
  type == 1 ? object.data = data : object.params = data;
  return request(object);
}
